package validate

import (
	"gin/common"
)

type AddPlayRoleWrapper struct {
	Data PlayRole `json:"data" binding:"required"`
}

type PlayRole struct {
	Id       uint64 `json:"id" gorm:"column:id;primaryKey;type:int;autoIncrement"`
	StoryId  uint64 `json:"story_id" binding:"required" gorm:"column:story_id;type:int"`
	PlayId   uint64 `json:"play_id" binding:"required"  gorm:"column:play_id;type:int"`
	RoleId   uint64 `json:"role_id" binding:"required"  gorm:"column:role_id;type:int"`
	RoleName string `json:"role_name" binding:"max=255" gorm:"column:role_name"`
	RoleCode string `json:"role_code" binding:"max=255" gorm:"column:role_code"`
}

type UpdatePlayRoleWrapper struct {
	Data struct {
		Id       uint64 `json:"id" binding:"required"`
		RoleName string `json:"role_name" binding:"max=255"`
		RoleCode string `json:"role_code" binding:"max=255"`
		StoryId  uint64 `json:"story_id"`
		PlayId   uint64 `json:"play_id"`
		RoleId   uint64 `json:"role_id"`
	} `json:"data" binding:"required"`
}

type SelectPlayRoleQuery struct {
	Param common.QueryParam `json:"param" binding:"required"`
}

type DeletePlayRoleParam struct {
	Param common.Filter `json:"param" binding:"required"`
}
